﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

using efish.Framework.Web;
using efish.Framework.Model;
using efish.Framework.Service;

public partial class Controls_ListProduct : BaseControl
{
    public IList<Product> Products
    {
        set 
        {
            if (value != null)
            {
                this.listProducts.DataSource = value;
            }
        }
    }

    private string _detailUrl = "~/store/ShowProduct.aspx?ID={0}";
    public string DetailUrl
    {
        get { return _detailUrl; }
        set { _detailUrl = value; }
    }

    private string _editUrl = "~/admin/EditProduct.aspx?ID={0}";
    public string EditUrl
    {
        get { return _editUrl; }
        set { _editUrl = value; }
    }

    private string _reviewUrl = "~/store/ShowReviews.aspx?PID={0}";
    public string ReviewUrl
    {
        get { return _reviewUrl; }
        set { _reviewUrl = value; }
    }

    private string _toCartUrl = "~/store/AddToCart.aspx?PID={0}";
    public string AddToCartUrl
    {
        get { return _toCartUrl; }
        set { _toCartUrl = value; }
    }
}
